Optimal. Leaf size=162 \[ \frac {x \left (-\left (x^2 (5 d+8 f+20 h)\right )+17 d+20 f+32 h\right )}{72 \left (x^4-5 x^2+4\right )}+\frac {1}{432} \tanh ^{-1}\left (\frac {x}{2}\right ) (19 d+52 f+112 h)-\frac {1}{54} \tanh ^{-1}(x) (d+7 f+13 h)+\frac {1}{54} \log \left (1-x^2\right ) (2 e+5 g+8 i)-\frac {1}{54} \log \left (4-x^2\right ) (2 e+5 g+8 i)+\frac {-\left (x^2 (2 e+5 g+17 i)\right )+5 e+8 g+20 i}{18 \left (x^4-5 x^2+4\right )} \]
________________________________________________________________________________________
Rubi [A] time = 0.23, antiderivative size = 162, normalized size of antiderivative = 1.00, number of steps used = 11, number of rules used = 9, integrand size = 38, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.237, Rules used = {1673, 1678, 1166, 207, 1663, 1660, 12, 616, 31} \begin {gather*} \frac {x \left (x^2 (-(5 d+8 f+20 h))+17 d+20 f+32 h\right )}{72 \left (x^4-5 x^2+4\right )}+\frac {1}{432} \tanh ^{-1}\left (\frac {x}{2}\right ) (19 d+52 f+112 h)-\frac {1}{54} \tanh ^{-1}(x) (d+7 f+13 h)+\frac {x^2 (-(2 e+5 g+17 i))+5 e+8 g+20 i}{18 \left (x^4-5 x^2+4\right )}+\frac {1}{54} \log \left (1-x^2\right ) (2 e+5 g+8 i)-\frac {1}{54} \log \left (4-x^2\right ) (2 e+5 g+8 i) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 31
Rule 207
Rule 616
Rule 1166
Rule 1660
Rule 1663
Rule 1673
Rule 1678
Rubi steps
\begin {align*} \int \frac {d+e x+f x^2+g x^3+h x^4+30 x^5}{\left (4-5 x^2+x^4\right )^2} \, dx &=\int \frac {x \left (e+g x^2+30 x^4\right )}{\left (4-5 x^2+x^4\right )^2} \, dx+\int \frac {d+f x^2+h x^4}{\left (4-5 x^2+x^4\right )^2} \, dx\\ &=\frac {x \left (17 d+20 f+32 h-(5 d+8 f+20 h) x^2\right )}{72 \left (4-5 x^2+x^4\right )}-\frac {1}{72} \int \frac {-d+20 f+32 h+(5 d+8 f+20 h) x^2}{4-5 x^2+x^4} \, dx+\frac {1}{2} \operatorname {Subst}\left (\int \frac {e+g x+30 x^2}{\left (4-5 x+x^2\right )^2} \, dx,x,x^2\right )\\ &=\frac {600+5 e+8 g-(510+2 e+5 g) x^2}{18 \left (4-5 x^2+x^4\right )}+\frac {x \left (17 d+20 f+32 h-(5 d+8 f+20 h) x^2\right )}{72 \left (4-5 x^2+x^4\right )}-\frac {1}{18} \operatorname {Subst}\left (\int \frac {240+2 e+5 g}{4-5 x+x^2} \, dx,x,x^2\right )-\frac {1}{54} (-d-7 f-13 h) \int \frac {1}{-1+x^2} \, dx-\frac {1}{216} (19 d+52 f+112 h) \int \frac {1}{-4+x^2} \, dx\\ &=\frac {600+5 e+8 g-(510+2 e+5 g) x^2}{18 \left (4-5 x^2+x^4\right )}+\frac {x \left (17 d+20 f+32 h-(5 d+8 f+20 h) x^2\right )}{72 \left (4-5 x^2+x^4\right )}+\frac {1}{432} (19 d+52 f+112 h) \tanh ^{-1}\left (\frac {x}{2}\right )-\frac {1}{54} (d+7 f+13 h) \tanh ^{-1}(x)-\frac {1}{18} (240+2 e+5 g) \operatorname {Subst}\left (\int \frac {1}{4-5 x+x^2} \, dx,x,x^2\right )\\ &=\frac {600+5 e+8 g-(510+2 e+5 g) x^2}{18 \left (4-5 x^2+x^4\right )}+\frac {x \left (17 d+20 f+32 h-(5 d+8 f+20 h) x^2\right )}{72 \left (4-5 x^2+x^4\right )}+\frac {1}{432} (19 d+52 f+112 h) \tanh ^{-1}\left (\frac {x}{2}\right )-\frac {1}{54} (d+7 f+13 h) \tanh ^{-1}(x)-\frac {1}{54} (-240-2 e-5 g) \operatorname {Subst}\left (\int \frac {1}{-1+x} \, dx,x,x^2\right )-\frac {1}{54} (240+2 e+5 g) \operatorname {Subst}\left (\int \frac {1}{-4+x} \, dx,x,x^2\right )\\ &=\frac {600+5 e+8 g-(510+2 e+5 g) x^2}{18 \left (4-5 x^2+x^4\right )}+\frac {x \left (17 d+20 f+32 h-(5 d+8 f+20 h) x^2\right )}{72 \left (4-5 x^2+x^4\right )}+\frac {1}{432} (19 d+52 f+112 h) \tanh ^{-1}\left (\frac {x}{2}\right )-\frac {1}{54} (d+7 f+13 h) \tanh ^{-1}(x)+\frac {1}{54} (240+2 e+5 g) \log \left (1-x^2\right )-\frac {1}{54} (240+2 e+5 g) \log \left (4-x^2\right )\\ \end {align*}
________________________________________________________________________________________
Mathematica [A] time = 0.09, size = 185, normalized size = 1.14 \begin {gather*} \frac {-5 d x^3+17 d x-8 e x^2+20 e-8 f x^3+20 f x-20 g x^2+32 g-20 h x^3+32 h x-68 i x^2+80 i}{72 \left (x^4-5 x^2+4\right )}+\frac {1}{108} \log (1-x) (d+4 e+7 f+10 g+13 h+16 i)+\frac {1}{864} \log (2-x) (-19 d-32 e-52 f-80 g-112 h-128 i)+\frac {1}{108} \log (x+1) (-d+4 e-7 f+10 g-13 h+16 i)+\frac {1}{864} \log (x+2) (19 d-32 e+52 f-80 g+112 h-128 i) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
IntegrateAlgebraic [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {d+e x+f x^2+g x^3+h x^4+i x^5}{\left (4-5 x^2+x^4\right )^2} \, dx \end {gather*}
Verification is not applicable to the result.
[In]
[Out]
________________________________________________________________________________________
fricas [B] time = 29.57, size = 346, normalized size = 2.14 \begin {gather*} -\frac {12 \, {\left (5 \, d + 8 \, f + 20 \, h\right )} x^{3} + 48 \, {\left (2 \, e + 5 \, g + 17 \, i\right )} x^{2} - 12 \, {\left (17 \, d + 20 \, f + 32 \, h\right )} x - {\left ({\left (19 \, d - 32 \, e + 52 \, f - 80 \, g + 112 \, h - 128 \, i\right )} x^{4} - 5 \, {\left (19 \, d - 32 \, e + 52 \, f - 80 \, g + 112 \, h - 128 \, i\right )} x^{2} + 76 \, d - 128 \, e + 208 \, f - 320 \, g + 448 \, h - 512 \, i\right )} \log \left (x + 2\right ) + 8 \, {\left ({\left (d - 4 \, e + 7 \, f - 10 \, g + 13 \, h - 16 \, i\right )} x^{4} - 5 \, {\left (d - 4 \, e + 7 \, f - 10 \, g + 13 \, h - 16 \, i\right )} x^{2} + 4 \, d - 16 \, e + 28 \, f - 40 \, g + 52 \, h - 64 \, i\right )} \log \left (x + 1\right ) - 8 \, {\left ({\left (d + 4 \, e + 7 \, f + 10 \, g + 13 \, h + 16 \, i\right )} x^{4} - 5 \, {\left (d + 4 \, e + 7 \, f + 10 \, g + 13 \, h + 16 \, i\right )} x^{2} + 4 \, d + 16 \, e + 28 \, f + 40 \, g + 52 \, h + 64 \, i\right )} \log \left (x - 1\right ) + {\left ({\left (19 \, d + 32 \, e + 52 \, f + 80 \, g + 112 \, h + 128 \, i\right )} x^{4} - 5 \, {\left (19 \, d + 32 \, e + 52 \, f + 80 \, g + 112 \, h + 128 \, i\right )} x^{2} + 76 \, d + 128 \, e + 208 \, f + 320 \, g + 448 \, h + 512 \, i\right )} \log \left (x - 2\right ) - 240 \, e - 384 \, g - 960 \, i}{864 \, {\left (x^{4} - 5 \, x^{2} + 4\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.32, size = 179, normalized size = 1.10 \begin {gather*} \frac {1}{864} \, {\left (19 \, d + 52 \, f - 80 \, g + 112 \, h - 128 \, i - 32 \, e\right )} \log \left ({\left | x + 2 \right |}\right ) - \frac {1}{108} \, {\left (d + 7 \, f - 10 \, g + 13 \, h - 16 \, i - 4 \, e\right )} \log \left ({\left | x + 1 \right |}\right ) + \frac {1}{108} \, {\left (d + 7 \, f + 10 \, g + 13 \, h + 16 \, i + 4 \, e\right )} \log \left ({\left | x - 1 \right |}\right ) - \frac {1}{864} \, {\left (19 \, d + 52 \, f + 80 \, g + 112 \, h + 128 \, i + 32 \, e\right )} \log \left ({\left | x - 2 \right |}\right ) - \frac {5 \, d x^{3} + 8 \, f x^{3} + 20 \, h x^{3} + 20 \, g x^{2} + 68 \, i x^{2} + 8 \, x^{2} e - 17 \, d x - 20 \, f x - 32 \, h x - 32 \, g - 80 \, i - 20 \, e}{72 \, {\left (x^{4} - 5 \, x^{2} + 4\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [B] time = 0.02, size = 362, normalized size = 2.23 \begin {gather*} -\frac {4 i \ln \left (x +2\right )}{27}+\frac {4 i \ln \left (x -1\right )}{27}+\frac {4 i \ln \left (x +1\right )}{27}-\frac {4 i \ln \left (x -2\right )}{27}+\frac {7 h \ln \left (x +2\right )}{54}+\frac {13 h \ln \left (x -1\right )}{108}-\frac {13 h \ln \left (x +1\right )}{108}-\frac {7 h \ln \left (x -2\right )}{54}+\frac {5 g \ln \left (x -1\right )}{54}-\frac {5 g \ln \left (x +2\right )}{54}-\frac {5 g \ln \left (x -2\right )}{54}+\frac {5 g \ln \left (x +1\right )}{54}+\frac {19 d \ln \left (x +2\right )}{864}-\frac {e \ln \left (x +2\right )}{27}+\frac {e \ln \left (x -1\right )}{27}+\frac {d \ln \left (x -1\right )}{108}+\frac {e \ln \left (x +1\right )}{27}-\frac {d \ln \left (x +1\right )}{108}-\frac {19 d \ln \left (x -2\right )}{864}-\frac {e \ln \left (x -2\right )}{27}-\frac {13 f \ln \left (x -2\right )}{216}-\frac {7 f \ln \left (x +1\right )}{108}+\frac {7 f \ln \left (x -1\right )}{108}+\frac {13 f \ln \left (x +2\right )}{216}+\frac {i}{36 x +36}+\frac {g}{18 x +36}+\frac {g}{36 x +36}+\frac {e}{36 x +36}+\frac {e}{72 x +144}+\frac {2 i}{9 \left (x +2\right )}-\frac {i}{36 \left (x -1\right )}-\frac {2 i}{9 \left (x -2\right )}-\frac {h}{9 \left (x +2\right )}-\frac {h}{36 \left (x +1\right )}-\frac {h}{36 \left (x -1\right )}-\frac {h}{9 \left (x -2\right )}-\frac {g}{36 \left (x -1\right )}-\frac {g}{18 \left (x -2\right )}-\frac {d}{144 \left (x +2\right )}-\frac {d}{144 \left (x -2\right )}-\frac {e}{72 \left (x -2\right )}-\frac {d}{36 \left (x +1\right )}-\frac {d}{36 \left (x -1\right )}-\frac {e}{36 \left (x -1\right )}-\frac {f}{36 \left (x -1\right )}-\frac {f}{36 \left (x +2\right )}-\frac {f}{36 \left (x -2\right )}-\frac {f}{36 \left (x +1\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 1.35, size = 163, normalized size = 1.01 \begin {gather*} \frac {1}{864} \, {\left (19 \, d - 32 \, e + 52 \, f - 80 \, g + 112 \, h - 128 \, i\right )} \log \left (x + 2\right ) - \frac {1}{108} \, {\left (d - 4 \, e + 7 \, f - 10 \, g + 13 \, h - 16 \, i\right )} \log \left (x + 1\right ) + \frac {1}{108} \, {\left (d + 4 \, e + 7 \, f + 10 \, g + 13 \, h + 16 \, i\right )} \log \left (x - 1\right ) - \frac {1}{864} \, {\left (19 \, d + 32 \, e + 52 \, f + 80 \, g + 112 \, h + 128 \, i\right )} \log \left (x - 2\right ) - \frac {{\left (5 \, d + 8 \, f + 20 \, h\right )} x^{3} + 4 \, {\left (2 \, e + 5 \, g + 17 \, i\right )} x^{2} - {\left (17 \, d + 20 \, f + 32 \, h\right )} x - 20 \, e - 32 \, g - 80 \, i}{72 \, {\left (x^{4} - 5 \, x^{2} + 4\right )}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.58, size = 164, normalized size = 1.01 \begin {gather*} \frac {\left (-\frac {5\,d}{72}-\frac {f}{9}-\frac {5\,h}{18}\right )\,x^3+\left (-\frac {e}{9}-\frac {5\,g}{18}-\frac {17\,i}{18}\right )\,x^2+\left (\frac {17\,d}{72}+\frac {5\,f}{18}+\frac {4\,h}{9}\right )\,x+\frac {5\,e}{18}+\frac {4\,g}{9}+\frac {10\,i}{9}}{x^4-5\,x^2+4}+\ln \left (x-1\right )\,\left (\frac {d}{108}+\frac {e}{27}+\frac {7\,f}{108}+\frac {5\,g}{54}+\frac {13\,h}{108}+\frac {4\,i}{27}\right )-\ln \left (x+1\right )\,\left (\frac {d}{108}-\frac {e}{27}+\frac {7\,f}{108}-\frac {5\,g}{54}+\frac {13\,h}{108}-\frac {4\,i}{27}\right )-\ln \left (x-2\right )\,\left (\frac {19\,d}{864}+\frac {e}{27}+\frac {13\,f}{216}+\frac {5\,g}{54}+\frac {7\,h}{54}+\frac {4\,i}{27}\right )+\ln \left (x+2\right )\,\left (\frac {19\,d}{864}-\frac {e}{27}+\frac {13\,f}{216}-\frac {5\,g}{54}+\frac {7\,h}{54}-\frac {4\,i}{27}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Timed out} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________